TSource
IdeaBlade DevForce 2010 Help Reference
DefaultIfEmpty<TSource>(IEntityQuery<TSource>) Method
See Also  Send Feedback
IdeaBlade.EntityModel Assembly > IdeaBlade.EntityModel Namespace > EntityQueryExtensions Class > DefaultIfEmpty Method : DefaultIfEmpty<TSource>(IEntityQuery<TSource>) Method



source
Returns the elements in a sequence or a default valued singleton collection if the sequence is empty.

Syntax

Visual Basic (Declaration) 
<ExtensionAttribute()>
Public Overloads Shared Function DefaultIfEmpty(Of TSource)( _
   ByVal source As IEntityQuery(Of TSource) _
) As IEntityQuery(Of TSource)
Visual Basic (Usage)Copy Code
Dim source As IEntityQuery(Of TSource)
Dim value As IEntityQuery(Of TSource)
 
value = EntityQueryExtensions.DefaultIfEmpty(Of TSource)(source)
C# 
[ExtensionAttribute()]
public static IEntityQuery<TSource> DefaultIfEmpty<TSource>( 
   IEntityQuery<TSource> source
)
C++/CLI 
[ExtensionAttribute()]
public:
static IEntityQuery<TSource^>^ DefaultIfEmptygeneric<typename TSource>
( 
   IEntityQuery<TSource^>^ source
) 

Parameters

source

Type Parameters

TSource

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

© 2013 All Rights Reserved.